package com.oedtech.esl.model.esl;

import com.oedtech.esl.model.sys.StoreBsid;
import org.hibernate.annotations.NotFound;
import org.hibernate.annotations.NotFoundAction;

import javax.persistence.*;
import java.io.Serializable;
import java.util.Date;

/**
 * @Author QiuLongYu
 * @Date 2019/7/30
 * 基站状态类
 */
@Entity
public class Ap implements Serializable{
    @Id
    private	String	apId	;	//	基站id
    private	String	status	;	//	基站状态
    private	String	mac	;	//	mac地址
    private Date onlineBeginTime	;	//	ap上线时间
    private	String	version	;	//	ap版本号
    private	String	workMode	;	//	当前状态，transmitting:工作中；standby:闲置中
    private	Date	lastWorkTime	;	//	最后一次工作时间
    private	String	netmask	;	//	子网掩码
    private	String	ip	;	//	IP地址
    private	String	sn	;	//	序列号
    private	String	gateway	;	//	网关
    @Column(name="description")
    private	String	desc	;	//	描述
    private	String	channel	;	//	信道号
    @OneToOne
    @JoinColumn(name = "apId",referencedColumnName="apId",insertable=false,updatable=false)
    @NotFound(action= NotFoundAction.IGNORE)
    private StoreBsid storeBsid;
    public String getApId() {
        return apId;
    }

    public void setApId(String apId) {
        this.apId = apId;
    }

    public String getStatus() {
        return status;
    }

    public void setStatus(String status) {
        this.status = status;
    }

    public String getMac() {
        return mac;
    }

    public void setMac(String mac) {
        this.mac = mac;
    }

    public Date getOnlineBeginTime() {
        return onlineBeginTime;
    }

    public void setOnlineBeginTime(Date onlineBeginTime) {
        this.onlineBeginTime = onlineBeginTime;
    }

    public String getVersion() {
        return version;
    }

    public void setVersion(String version) {
        this.version = version;
    }

    public String getWorkMode() {
        return workMode;
    }

    public void setWorkMode(String workMode) {
        this.workMode = workMode;
    }

    public Date getLastWorkTime() {
        return lastWorkTime;
    }

    public void setLastWorkTime(Date lastWorkTime) {
        this.lastWorkTime = lastWorkTime;
    }

    public String getNetmask() {
        return netmask;
    }

    public void setNetmask(String netmask) {
        this.netmask = netmask;
    }

    public String getIp() {
        return ip;
    }

    public void setIp(String ip) {
        this.ip = ip;
    }

    public String getSn() {
        return sn;
    }

    public void setSn(String sn) {
        this.sn = sn;
    }

    public String getGateway() {
        return gateway;
    }

    public void setGateway(String gateway) {
        this.gateway = gateway;
    }

    public String getDesc() {
        return desc;
    }

    public void setDesc(String desc) {
        this.desc = desc;
    }

    public String getChannel() {
        return channel;
    }

    public void setChannel(String channel) {
        this.channel = channel;
    }

    public StoreBsid getStoreBsid() {
        return storeBsid;
    }

    public void setStoreBsid(StoreBsid storeBsid) {
        this.storeBsid = storeBsid;
    }
}
